﻿<Page x:Name="page_games" x:Class="WGM.PageGames"
      xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
      xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
      xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
      xmlns:metro="http://schemas.codeplex.com/elysium"
      xmlns:params="http://schemas.codeplex.com/elysium/params"
      mc:Ignorable="d" 
      d:DesignHeight="499" d:DesignWidth="1042"
	Title="PageGames" Width="Auto" Height="Auto" Loaded="page_games_Loaded">

    <Page.Resources>
        <Storyboard Name="loadingon" x:Key="loadingon">
            <DoubleAnimation Storyboard.TargetName="webbrowser_defiance" Storyboard.TargetProperty="Opacity" From="0" To="1" Duration="0:0:0.4" BeginTime="0:0:0" />
        </Storyboard>
    </Page.Resources>

    <Grid x:Name="gid_games" Background="{Binding Background, ElementName=tabControl}">
        <Grid.RowDefinitions>
            <RowDefinition Height="149*"/>
            <RowDefinition Height="12*"/>
        </Grid.RowDefinitions>
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="auto"/>
            <ColumnDefinition Width="378*"/>
        </Grid.ColumnDefinitions>
        <Label x:Name="label_left" Content="7" VerticalAlignment="Top" HorizontalContentAlignment="Center" FontFamily="Webdings" FontSize="14" Cursor="Hand" Margin="20,14,198,0" MouseLeftButtonUp="label_left_MouseLeftButtonUp" Foreground="{Binding Foreground, ElementName=tabControl}"/>
        <Label x:Name="label_selection" Foreground="{Binding Foreground, ElementName=tabControl}" Content="All Games" Margin="34,10,27,0" FontFamily="Segoe UI Semibold" FontSize="14" VerticalAlignment="Top" HorizontalContentAlignment="Center" MouseLeftButtonUp="label_selection_MouseLeftButtonUp" Cursor="Hand"/>
        <Label x:Name="label_right" Foreground="{Binding Foreground, ElementName=tabControl}" Content="8" VerticalAlignment="Top" HorizontalContentAlignment="Center" FontFamily="Webdings" FontSize="14" Cursor="Hand" Margin="205,15,13,0" MouseLeftButtonUp="label_right_MouseLeftButtonUp"/>
        <Grid Margin="10,44,3,0" metro:ApplicationBar.PreventsOpen="true">
            <ListBox x:Name="listbox_gamelist" SelectionChanged="listbox_gamelist_SelectionChanged">
                <ListBox.ContextMenu>
                    <ContextMenu>
                        <MenuItem x:Name="menuitem_selected3" Header="See the review" Click="menuitem_selected3_Click"/>
                        <MenuItem x:Name="menuitem_selected2" Header="See statistic" Click="menuitem_selected2_Click"/>
                        <MenuItem IsEnabled="False" Header="----------------------"/>
                        <MenuItem x:Name="menuitem_selected4" Header="Edit game detail" Click="menuitem_selected4_Click"/>
                        <MenuItem x:Name="menuitem_selected5" Header="Favorite this game" Click="menuitem_selected5_Click"/>
                        <MenuItem IsEnabled="False" Header="----------------------"/>
                        <MenuItem x:Name="menuitem_selected0" Header="Start the game" Click="menuitem_selected0_Click"/>
                        <MenuItem x:Name="menuitem_selected1" Header="Backup the savefile" Click="menuitem_selected1_Click"/>
                    </ContextMenu>
                </ListBox.ContextMenu>
            </ListBox>
        </Grid>
        <TabControl x:Name="tabControl" Margin="6,0,10,10" Grid.Column="1" Grid.RowSpan="2">
            <TabItem x:Name="tab_detail" Header="Detail" BorderBrush="{x:Null}" Background="{x:Null}">
                <Grid x:Name="grid_detail">
                    <Label x:Name="labewl_status" Content="Status" Foreground="{Binding Foreground, ElementName=tabControl}" HorizontalAlignment="Left" Margin="10,10,0,0" VerticalAlignment="Top" FontSize="12" FontWeight="Bold"/>
                    <Label Content="Type" Foreground="{Binding Foreground, ElementName=tabControl}" HorizontalAlignment="Left" Margin="10,41,0,0" VerticalAlignment="Top" FontSize="12" FontWeight="Bold"/>
                    <Label Content="Backup" Foreground="{Binding Foreground, ElementName=tabControl}" HorizontalAlignment="Left" Margin="10,72,0,0" VerticalAlignment="Top" FontSize="12" FontWeight="Bold"/>
                    <Label Content="Compatibility" Foreground="{Binding Foreground, ElementName=tabControl}" HorizontalAlignment="Left" Margin="10,103,0,0" VerticalAlignment="Top" FontSize="12" FontWeight="Bold"/>
                    <Label Content="Playtime" Foreground="{Binding Foreground, ElementName=tabControl}" HorizontalAlignment="Left" Margin="10,134,0,0" VerticalAlignment="Top" FontSize="12" FontWeight="Bold"/>
                    <Label Content="Last Played" Foreground="{Binding Foreground, ElementName=tabControl}" HorizontalAlignment="Left" Margin="10,165,0,0" VerticalAlignment="Top" FontSize="12" FontWeight="Bold"/>
                    <Label Content="Playtype" Foreground="{Binding Foreground, ElementName=tabControl}" HorizontalAlignment="Left" Margin="10,196,0,0" VerticalAlignment="Top" FontSize="12" FontWeight="Bold"/>
                    <Label Content="Description" Foreground="{Binding Foreground, ElementName=tabControl}" HorizontalAlignment="Left" Margin="10,256,0,0" VerticalAlignment="Top" FontSize="12" FontWeight="Bold"/>
                    <Label Content="Completed" Foreground="{Binding Foreground, ElementName=tabControl}" HorizontalAlignment="Left" Margin="10,226,0,0" VerticalAlignment="Top" FontSize="12" FontWeight="Bold"/>
                    <TextBox x:Name="textbox_rstatus" HorizontalAlignment="Left" Height="23" Margin="115,12,0,0" TextWrapping="Wrap" VerticalAlignment="Top" FontSize="12" FontFamily="Segoe UI" VerticalContentAlignment="Center" BorderBrush="{x:Null}" BorderThickness="0" IsReadOnly="True"/>
                    <TextBox x:Name="textbox_rtype" HorizontalAlignment="Left" Height="23" Margin="115,43,0,0" TextWrapping="Wrap" VerticalAlignment="Top" FontSize="12" FontFamily="Segoe UI" VerticalContentAlignment="Center" BorderBrush="{x:Null}" BorderThickness="0" IsReadOnly="True"/>
                    <TextBox x:Name="textbox_rbackup" HorizontalAlignment="Left" Height="23" Margin="115,74,0,0" TextWrapping="Wrap" VerticalAlignment="Top" FontSize="12" FontFamily="Segoe UI" VerticalContentAlignment="Center" BorderBrush="{x:Null}" BorderThickness="0" IsReadOnly="True"/>
                    <TextBox x:Name="textbox_rcomp" HorizontalAlignment="Left" Height="23" Margin="115,105,0,0" TextWrapping="Wrap" VerticalAlignment="Top" FontSize="12" FontFamily="Segoe UI" VerticalContentAlignment="Center" BorderBrush="{x:Null}" BorderThickness="0" IsReadOnly="True"/>
                    <TextBox x:Name="textbox_rplaytime" HorizontalAlignment="Left" Height="23" Margin="115,136,0,0" TextWrapping="Wrap" VerticalAlignment="Top" FontSize="12" FontFamily="Segoe UI" VerticalContentAlignment="Center" BorderBrush="{x:Null}" BorderThickness="0" IsReadOnly="True"/>
                    <TextBox x:Name="textbox_rlastplayed" HorizontalAlignment="Left" Height="23" Margin="115,167,0,0" TextWrapping="Wrap" VerticalAlignment="Top" FontSize="12" FontFamily="Segoe UI" VerticalContentAlignment="Center" BorderBrush="{x:Null}" BorderThickness="0" IsReadOnly="True"/>
                    <TextBox x:Name="textbox_rplaytype" HorizontalAlignment="Left" Height="23" Margin="115,198,0,0" TextWrapping="Wrap" VerticalAlignment="Top" FontSize="12" FontFamily="Segoe UI" VerticalContentAlignment="Center" BorderBrush="{x:Null}" BorderThickness="0" IsReadOnly="True"/>
                    <TextBox x:Name="textbox_rcompleted" HorizontalAlignment="Left" Height="23" Margin="115,228,0,0" TextWrapping="Wrap" VerticalAlignment="Top" FontSize="12" FontFamily="Segoe UI" VerticalContentAlignment="Center" BorderBrush="{x:Null}" BorderThickness="0" IsReadOnly="True"/>
                    <ScrollViewer Margin="11,286,0,0" VerticalScrollBarVisibility="Auto">
                        <TextBox x:Name="textbox_descp" TextWrapping="Wrap" FontSize="12" FontFamily="Segoe UI" BorderBrush="{x:Null}" BorderThickness="0" AcceptsReturn="True" IsReadOnly="True" VerticalContentAlignment="Top"/>
                    </ScrollViewer>
                    <Image x:Name="image_cover" Margin="0,14,14,0" Source="Resources/WGM_icon_dark.png" Height="225" VerticalAlignment="Top" HorizontalAlignment="Right" Width="165">
                        <Image.Effect>
                            <DropShadowEffect Direction="290" BlurRadius="20"/>
                        </Image.Effect>
                    </Image>
                    <metro:ToggleSwitch x:Name="switch_favorite" Margin="0,16,215,0" Checked="switch_favorite_Checked" Unchecked="switch_favorite_Unchecked" HorizontalAlignment="Right" Width="100" VerticalAlignment="Top"/>
                    <Label x:Name="labewl_status_Copy" Content="Favorite" Foreground="{Binding Foreground, ElementName=tabControl}" VerticalAlignment="Top" FontSize="12" FontWeight="Bold" HorizontalAlignment="Right" Margin="0,11,263,0"/>
                </Grid>
            </TabItem>
            <TabItem x:Name="tab_review" Header="Review" BorderBrush="{x:Null}" Background="{x:Null}">
                <Grid x:Name="gird_review">
                    <Grid.ColumnDefinitions>
                        <ColumnDefinition Width="93*"/>
                        <ColumnDefinition Width="92*"/>
                    </Grid.ColumnDefinitions>
                    <ComboBox x:Name="comboxbox_note" Margin="10,10,10,0" VerticalAlignment="Top" HorizontalContentAlignment="Center" IsReadOnly="True" BorderThickness="0" Height="31" Grid.ColumnSpan="2">
                        <ComboBoxItem Content="10 (Masterpiece)"/>
                        <ComboBoxItem Content="9 (Amazing)"/>
                        <ComboBoxItem Content="8 (Great)"/>
                        <ComboBoxItem Content="7 (Good)"/>
                        <ComboBoxItem Content="6 (Okay)"/>
                        <ComboBoxItem Content="5 (Mediocre)"/>
                        <ComboBoxItem Content="4 (Bad)"/>
                        <ComboBoxItem Content="3 (Awful)"/>
                        <ComboBoxItem Content="2 (Painful)"/>
                        <ComboBoxItem Content="1 (Unbearable)"/>
                        <ComboBoxItem Content="0 (Disaster)"/>
                    </ComboBox>
                    <TextBox x:Name="textbox_note" Margin="10,10,10,0" IsReadOnly="True" BorderThickness="0" Height="31" VerticalAlignment="Top" HorizontalContentAlignment="Center" FontSize="13.333" Grid.ColumnSpan="2"/>
                    <TextBox x:Name="textbox_thegood" Margin="10,46,1,46" TextWrapping="Wrap" FlowDirection="RightToLeft" BorderThickness="0" VerticalContentAlignment="Top" IsReadOnly="True" AcceptsReturn="True"/>
                    <TextBox x:Name="textbox_thebad" Margin="0,46,10,46" TextWrapping="Wrap" BorderThickness="0" VerticalContentAlignment="Top" AcceptsReturn="True" IsReadOnly="True" Grid.Column="1"/>
                    <Button x:Name="button_edit" Content="Edit" Margin="0,0,10,10" Height="31" VerticalAlignment="Bottom" HorizontalAlignment="Right" Width="100" Click="button_edit_Click" Grid.Column="1"/>
                </Grid>
            </TabItem>
            <TabItem x:Name="tab_edit" Header="Edit" BorderBrush="{x:Null}" Background="{x:Null}">
                <Grid x:Name="gid_edit">
                    <Grid.ColumnDefinitions>
                        <ColumnDefinition Width="373*"/>
                        <ColumnDefinition Width="367*"/>
                    </Grid.ColumnDefinitions>
                    <Label Content="Type" Foreground="{Binding Foreground, ElementName=tabControl}" HorizontalAlignment="Left" Margin="10,63,0,0" VerticalAlignment="Top" FontSize="12"/>
                    <Label Content="Compatibility" Foreground="{Binding Foreground, ElementName=tabControl}" HorizontalAlignment="Left" Margin="10,94,0,0" VerticalAlignment="Top" FontSize="12"/>
                    <Label Content="Description" Foreground="{Binding Foreground, ElementName=tabControl}" HorizontalAlignment="Left" Margin="10,125,0,0" VerticalAlignment="Top" FontSize="12"/>
                    <ComboBox x:Name="combobox_type" HorizontalAlignment="Left" Margin="115,66,0,0" VerticalAlignment="Top" FontFamily="Segoe UI" FontSize="12">
                        <ComboBoxItem Content="Action"/>
                        <ComboBoxItem Content="Aventure"/>
                        <ComboBoxItem Content="FPS"/>
                        <ComboBoxItem Content="MMORPG"/>
                        <ComboBoxItem Content="Racing"/>
                        <ComboBoxItem Content="RPG"/>
                        <ComboBoxItem Content="Simulation"/>
                        <ComboBoxItem Content="Strategy"/>
                        <ComboBoxItem Content="Survival"/>
                    </ComboBox>
                    <ComboBox x:Name="combobox_comp" HorizontalAlignment="Left" Margin="115,97,0,0" VerticalAlignment="Top" FontFamily="Segoe UI" FontSize="12">
                        <ComboBoxItem Content="Windows 8"/>
                        <ComboBoxItem Content="Windows 8 Fix"/>
                        <ComboBoxItem Content="Broken"/>
                    </ComboBox>
                    <ScrollViewer Margin="11,155,10,80" VerticalScrollBarVisibility="Auto" Grid.ColumnSpan="2">
                        <TextBox x:Name="textbox_descpedit" TextWrapping="Wrap" FontSize="12" FontFamily="Segoe UI" BorderBrush="{x:Null}" BorderThickness="0" AcceptsReturn="True" VerticalContentAlignment="Top"/>
                    </ScrollViewer>
                    <Button x:Name="button_save" Content="Save" Margin="0,52,10,0" HorizontalAlignment="Right" Width="125" Height="36" VerticalAlignment="Top" Click="button_save_Click" Grid.Column="1"/>
                    <Button x:Name="button_cover" Content="Set CoverArt" HorizontalAlignment="Left" Margin="10,0,0,10" Width="180" Height="31" VerticalAlignment="Bottom" Click="button_cover_Click"/>
                    <Button x:Name="button_path" Content="Set path to Savegame" Margin="0,0,10,10" Height="31" VerticalAlignment="Bottom" HorizontalAlignment="Right" Width="180" Click="button_path_Click" Grid.Column="1"/>
                    <Button x:Name="button_exe" Content="Set path to Exe" Margin="280,0,280,10" VerticalAlignment="Bottom" Click="button_exe_Click" Width="180" Grid.ColumnSpan="2"/>
                    <Label Content="External Action" Foreground="{Binding Foreground, ElementName=tabControl}" Margin="0,0,0,49" FontSize="12" BorderBrush="{Binding Foreground, ElementName=tabControl}" Height="26" VerticalAlignment="Bottom" HorizontalContentAlignment="Center" BorderThickness="0,0,0,1" Grid.ColumnSpan="2"/>
                    <Label Content="Internal Action" Foreground="{Binding Foreground, ElementName=tabControl}" BorderBrush="{Binding Foreground, ElementName=tabControl}" Margin="-10,11,10,0" FontSize="12" Height="26" VerticalAlignment="Top" HorizontalContentAlignment="Center" BorderThickness="0,0,0,1" Grid.ColumnSpan="2"/>
                    <CheckBox x:Name="checkbox_completed" Content="Completed" Margin="0,125,10,0" VerticalAlignment="Top" FontSize="12" RenderTransformOrigin="0.027,4.8" HorizontalAlignment="Right" Width="80" Grid.Column="1"/>
                    <CheckBox x:Name="checkbox_steam" Content="Steam" Margin="97,0,0,16" FontSize="12" RenderTransformOrigin="0.027,4.8" FontFamily="Segoe UI" Height="16" VerticalAlignment="Bottom" Grid.Column="1" HorizontalAlignment="Left" Width="80"/>
                    <Rectangle x:Name="rectangle_steam" Margin="229,0,234,73" RadiusX="2" RadiusY="2" Fill="{Binding Background, ElementName=tabControl}" Stroke="{Binding Foreground, ElementName=tabControl}" Grid.ColumnSpan="2" Height="117" VerticalAlignment="Bottom" HorizontalAlignment="Center" Width="277"/>
                    <Label x:Name="label_steam" Foreground="{Binding Foreground, ElementName=tabControl}" Content="Steam API Number" Margin="238,0,244,159" Background="{x:Null}" HorizontalContentAlignment="Center" Grid.ColumnSpan="2" HorizontalAlignment="Center" Width="258" Height="25" VerticalAlignment="Bottom"/>
                    <TextBox x:Name="textbox_steam" Height="23" Margin="238,0,244,131" TextWrapping="Wrap" VerticalAlignment="Bottom" FontFamily="Segoe UI" FontSize="14" Grid.ColumnSpan="2" HorizontalAlignment="Center" Width="258"/>
                    <Button x:Name="button_steam" Content="Save" Margin="317,0,323,86" Click="Button_Click_1" Grid.ColumnSpan="2" HorizontalAlignment="Center" Width="100" Height="31" VerticalAlignment="Bottom"/>
                </Grid>
            </TabItem>
            <TabItem x:Name="tabitem_defiance" Header="Forum" BorderBrush="{x:Null}" Background="{x:Null}" MouseLeftButtonUp="tabitem_defiance_MouseLeftButtonUp">
                <Grid x:Name="grid_defiance">
                    <WebBrowser x:Name="webbrowser_defiance" Navigated="webbrowser_defiance_Navigated" Source="{x:Null}" Opacity="0"/>
                    <metro:ProgressRing x:Name="progressring_defiance" State="Busy" Margin="100" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch" Width="241" Height="241"/>
                </Grid>
            </TabItem>
        </TabControl>
        <Label x:Name="label_gamestart_text" Foreground="{Binding Foreground, ElementName=tabControl}" Content="Launch and Play" VerticalAlignment="Top" FontFamily="Segoe UI Semibold" FontSize="14" Grid.Column="1" HorizontalAlignment="Right" Margin="0,6,33,0" HorizontalContentAlignment="Right" VerticalContentAlignment="Bottom"/>
        <Label x:Name="label_gamestart" Foreground="{Binding Foreground, ElementName=tabControl}" Content="4" VerticalAlignment="Top" HorizontalContentAlignment="Right" FontFamily="Webdings" FontSize="30" Cursor="Hand" Margin="0,1,0,0" Grid.Column="1" HorizontalAlignment="Right" Width="146" MouseLeftButtonUp="label_gamestart_MouseLeftButtonUp" VerticalContentAlignment="Bottom"/>
        <TextBox x:Name="textbox_completionstatus" TextWrapping="Wrap" Grid.Column="1" Margin="0,6,156,0" HorizontalAlignment="Right" Width="190" Height="29" VerticalAlignment="Top"/>
        <Label x:Name="label_completionstatus" Content="Completion status" Grid.Column="1" Foreground="{Binding Foreground, ElementName=tabControl}" Margin="343,8,0,0" HorizontalAlignment="Left" VerticalAlignment="Top"/>
        <TextBox x:Name="textbox_search" Margin="10,3,3,10" TextWrapping="Wrap" Grid.Row="1" BorderThickness="0,0,0,1" VerticalContentAlignment="Bottom" KeyUp="textbox_search_KeyUp"/>
        <Rectangle x:Name="rectangle_stats" Margin="0,0,30,10" RadiusX="2" RadiusY="2" Fill="{Binding Background, ElementName=tabControl}" Stroke="{Binding Foreground, ElementName=tabControl}" Height="188" VerticalAlignment="Bottom" HorizontalAlignment="Right" Width="277" Grid.Column="1"/>
        <Label x:Name="label_stats" Content="Total Playtime:" Foreground="{Binding Foreground, ElementName=tabControl}" Margin="0,0,206,161" FontFamily="Segoe WP Semibold" Grid.Column="1" HorizontalAlignment="Right" Width="91" Height="26" VerticalAlignment="Bottom" />
        <TextBox x:Name="textbox_playtime" Margin="0,0,40,162" TextWrapping="Wrap" FontSize="12" FontFamily="Segoe UI" VerticalContentAlignment="Center" BorderBrush="{x:Null}" BorderThickness="0" IsReadOnly="True" Grid.Column="1" HorizontalAlignment="Right" Width="161" Height="23" VerticalAlignment="Bottom"/>
        <Button x:Name="button_stats" Content="Close" Margin="0,0,40,20" HorizontalAlignment="Right" Width="100" Height="31" VerticalAlignment="Bottom" Grid.Column="1" Click="button_stats_Click"/>
        <Label x:Name="label_avgsession" Content="Avg Session:" Foreground="{Binding Foreground, ElementName=tabControl}" Margin="0,0,206,130" FontFamily="Segoe WP Semibold" Grid.Column="1" HorizontalAlignment="Right" Width="91" Height="26" VerticalAlignment="Bottom" />
        <TextBox x:Name="textbox_avgsession" Margin="0,0,40,131" TextWrapping="Wrap" FontSize="12" FontFamily="Segoe UI" VerticalContentAlignment="Center" BorderBrush="{x:Null}" BorderThickness="0" IsReadOnly="True" Grid.Column="1" HorizontalAlignment="Right" Width="161" Height="23" VerticalAlignment="Bottom"/>
        <Label x:Name="label_lplay" Content="Longest Play:" Foreground="{Binding Foreground, ElementName=tabControl}" Margin="0,0,206,99" FontFamily="Segoe WP Semibold" Grid.Column="1" HorizontalAlignment="Right" Width="91" Height="26" VerticalAlignment="Bottom" />
        <TextBox x:Name="textbox_lplay" Margin="0,0,40,100" TextWrapping="Wrap" FontSize="12" FontFamily="Segoe UI" VerticalContentAlignment="Center" BorderBrush="{x:Null}" BorderThickness="0" IsReadOnly="True" Grid.Column="1" HorizontalAlignment="Right" Width="161" Height="23" VerticalAlignment="Bottom"/>
        <Label x:Name="label_session" Content="Played:" Foreground="{Binding Foreground, ElementName=tabControl}" Margin="0,0,206,68" FontFamily="Segoe WP Semibold" Grid.Column="1" HorizontalAlignment="Right" Width="91" Height="26" VerticalAlignment="Bottom" />
        <TextBox x:Name="textbox_session" Margin="0,0,40,69" TextWrapping="Wrap" FontSize="12" FontFamily="Segoe UI" VerticalContentAlignment="Center" BorderBrush="{x:Null}" BorderThickness="0" IsReadOnly="True" Grid.Column="1" HorizontalAlignment="Right" Width="161" Height="23" VerticalAlignment="Bottom"/>
    </Grid>
</Page>